The field of the invention generally relates to caching data and, more specifically to allocating cache for use as a dedicated local storage.
Conventional data caches are configured to store data that is frequently accessed by a processor to reduce the latency needed to read and write the data to a backing memory. Data caches also reduce the bandwidth consumed between the processor and backing memory since data is only read from the backing memory and stored in the cache when a cache miss occurs. Similarly, writes to the backing memory may be reduced when the data cache is used since data is copied from the cache to the backing memory when the data is evicted from the data cache.
In order to allow a data cache to also serve as a dedicated local storage, one conventional data cache may be configured in a mode that converts half of the data cache storage for use as a fixed size dedicated local storage. The half of the data cache includes only contiguous cache lines. Furthermore, the contiguous cache lines of the dedicated local storage are accessed using addresses that are outside of the address range of the backing memory. The size of the dedicated local storage is fixed and the cache lines that are configured to form the dedicated local storage are also fixed.